import React from 'react'
import { BrowserRouter as Router, Route, Redirect } from 'react-router-dom'

import 'antd-mobile/dist/antd-mobile.css'
import './css/index.css'
import 'react-virtualized/styles.css'

import Home from './pages/Home'
import CityList from './pages/CityList'
import Map from './pages/Map'
import Login from './pages/Login'

export default () => {
  return (
    <Router>
      <Route exact path="/" render={() => <Redirect to="/home" />}></Route>
      <Route path="/home" component={Home}></Route>
      <Route path="/cityList" component={CityList}></Route>
      <Route path="/map" component={Map}></Route>
      <Route path="/login" component={Login}></Route>
    </Router>
  )
}
